CREATE TABLE Staff (Name varchar(255), ID int(10) NOT NULL AUTO_INCREMENT, TransactionID int(10) NOT NULL, PRIMARY KEY (ID)) type=InnoDB;
CREATE TABLE Transaction (`Date` date, Price double NOT NULL, ID int(10) NOT NULL AUTO_INCREMENT, PRIMARY KEY (ID)) type=InnoDB;
CREATE TABLE Pet (ID int(10) NOT NULL AUTO_INCREMENT, Injection date, Source varchar(255), Type varchar(255), TransactionID2 int(10), PRIMARY KEY (ID)) type=InnoDB;
CREATE TABLE Customer (Name varchar(255), Telephone varchar(255), Address varchar(255), ID int(10) NOT NULL AUTO_INCREMENT, TransactionID int(10) NOT NULL, PRIMARY KEY (ID)) type=InnoDB;
ALTER TABLE Staff ADD INDEX FKStaff557563 (TransactionID), ADD CONSTRAINT FKStaff557563 FOREIGN KEY (TransactionID) REFERENCES Transaction (ID);
ALTER TABLE Customer ADD INDEX FKCustomer173000 (TransactionID), ADD CONSTRAINT FKCustomer173000 FOREIGN KEY (TransactionID) REFERENCES Transaction (ID);
ALTER TABLE Pet ADD INDEX FKPet201932 (TransactionID2), ADD CONSTRAINT FKPet201932 FOREIGN KEY (TransactionID2) REFERENCES Transaction (ID);
